#ifndef MUTEX_HPP
#define MuTEX_HPP

#include <pthread.h>

class Mutex
{
private:
    pthread_mutex_t _mutex;
public:
    Mutex()
    {
        pthread_mutex_init(&_mutex,nullptr);
    }

    void lock()
    {
        pthread_mutex_lock(&_mutex);
    }

    void unlock()
    {
        pthread_mutex_unlock(&_mutex);
    }

    ~Mutex()
    {
        pthread_mutex_destroy(&_mutex);
    }
};


#endif